package cn.theten52.demo.patterns.design.behavior.mediation.update3;

/**
 * 抽象中介者
 *
 * @author wangjin
 * @date 2021/4/4
 */
public abstract class AbstractColleague<T> implements Colleague<T> {

    protected T data;
    protected Mediator<T> mediator;

    @Override
    public T getData() {
        return data;
    }

    @Override
    public Colleague<T> setData(T data) {
        this.data = data;
        return this;
    }

    @Override
    public Mediator<T> getMediator() {
        return mediator;
    }

    @Override
    public Colleague<T> setMediator(Mediator<T> mediator) {
        this.mediator = mediator;
        return this;
    }
}
